package com.umakr.ax.app.web;

import java.util.Date;
import java.util.Map;

import com.umakr.ax.app.service.RadioStationFollowerWebService;
import com.umakr.ax.common.service.RadioStationFollowerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.ui.ModelMap;
import com.umakr.ax.common.model.RadioStationFollower;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

import com.umakr.ax.core.base.AbstractController;

/**
 * <p>
 * 电台粉丝  前端控制器
 * </p>
 *
 * @author Umakr-Code-Generator
 * @since 2017-12-30
 */
@Controller
@RequestMapping("/api/web/radioStationFollower")
public class RadioStationFollowerWebController extends AbstractController {
	@Autowired
	RadioStationFollowerWebService radioStationFollowerWebService;

	@ApiOperation(value = "关注电台的粉丝列表")
	@GetMapping(value = "/listFollowers")
	@ResponseBody
	public Object listFollowers(ModelMap modelMap,@RequestParam(name = "rsId") Long rsId,@RequestParam(name = "nickName") String nickName) {
		return setSuccessModelMap(modelMap,radioStationFollowerWebService.listFollowers(rsId,nickName));
	}

	@ApiOperation(value = "删除粉丝")
	@GetMapping(value = "/delFollowers")
	@ResponseBody
	public Object delFollowers(ModelMap modelMap,@RequestParam(name = "ids") String ids) {
		return setSuccessModelMap(modelMap,radioStationFollowerWebService.delFollowers(ids));
	}
}